/*
 * Notes:
 * 1. this is a sub-class of SystemUserEntity
 */
package entity;

import java.util.Collection;
import javax.persistence.Entity;
import javax.persistence.OneToMany;

/**
 *
 * @author Ye Mei
 */
@Entity(name="Employee")
public class EmployeeEntity extends SystemUserEntity {
    private String department;
    private String position;
    
    @OneToMany(mappedBy="employee")
    private Collection<SolutionEntity> solutions;
    @OneToMany
    private Collection<ClientCaseEntity> cases;

    public EmployeeEntity() {
    }

    public void create(String department, String position) {
        this.department = department;
        this.position = position;
    }

    public String getDepartment() {
        return department;
    }

    public void setDepartment(String department) {
        this.department = department;
    }

    public String getPosition() {
        return position;
    }

    public void setPosition(String position) {
        this.position = position;
    }

    public Collection<SolutionEntity> getSolutions() {
        return solutions;
    }

    public void setSolutions(Collection<SolutionEntity> solutions) {
        this.solutions = solutions;
    }

    public Collection<ClientCaseEntity> getCases() {
        return cases;
    }

    public void setCases(Collection<ClientCaseEntity> cases) {
        this.cases = cases;
    }
    
}
